An APK (Android Package) eigenvalue is able to uniquely determine the version of an APK file as well as the base file thereof used in an incremental upgrading, in which the base file refers to the original file. The APK eigenvalue can be obtained through the APK version number. However, in some special cases, the eigenvalue cannot be directly obtained from the version number.
At present, typically it employs MD5 (Message-Digest Algorithm 5) or SHA (Secure Hash Algorithm)-1 and other traditional algorithms to carry out a calculation for the entire data of the APK file in order to obtain the APK eigenvalue of that file. However, for the purpose of commercial distribution, currently every APK developer, during the APK releasing process, adds certain special identifiers in APK in order to differentiate different distribution channels. As a result, due to the foregoing practice for APK, the traditional approaches for obtaining APK eigenvalue of an APK file become no longer applicable. This is because even if they share the same base file, with the addition of the special identifiers, they would become different APK files. In such a case, when using the traditional approach for obtaining APK eigenvalue to acquire the APK eigenvalue of an APK file, it may result in the problems as follows:
1. The calculation for obtaining APK eigenvalue is quite large, and the calculation efficiency is very low.
2. In general, an APK file may have thousands of distribution channels. Accordingly, even for the APK files of the same version, when they are added with different special identifiers, they essentially become thousands of different APK files; and as a result, they would have thousands of corresponding APK eigenvalues. It is noted that for those thousands of different APK files, a majority of their contents is exactly the same, and only a small number of data are different. However, if the thousands of different APK files are treated as different files in an incremental upgrading process, the background maintenance workload for the upgrading would be very huge.